cmake_minimum_required(VERSION 3.14)
project(CppSimpleCommandLineImpl LANGUAGES CXX)

set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

include(IncludeDefine.cmake)
set(CMAKE_PREFIX_PATH ${QT_DIR})

add_subdirectory(LibNetImpl)
find_package(Qt6 REQUIRED COMPONENTS Core)

add_executable(${PROJECT_NAME}
    main.cpp
)
target_link_libraries(${PROJECT_NAME}
    Qt6::Core
    LibNetImpl
)

include(GNUInstallDirs)
install(TARGETS ${PROJECT_NAME}
    LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
    RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
)
